package com.efast.dmom.equipment.statemach.handler.repair;

import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import com.alibaba.fastjson.JSONObject;
//import com.efast.cafe.commponent.statemach.annotation.StatemachHandle;
//import com.efast.cafe.commponent.statemach.base.HandleBaseProcessorService;
import com.efast.dmom.equipment.bean.repair.EquipRepairOrderDetailsBean;
import com.efast.dmom.equipment.service.repair.IEquipRepairOrderService;
import com.efast.dmom.equipment.statemach.handler.base.HandleBaseProcessorService;

/**
 * 
 * @author 作者 Aaron Liu:
 * 
 * @version 创建时间：2019年8月19日 下午4:50:58
 * 
 *          类说明
 * 
 */
@Component
//@StatemachHandle(handleName = "savedraft", configId = 1010, entityName = "repairOrderDetails")
public class EquipRepairDetailsDraftHandler implements HandleBaseProcessorService<EquipRepairOrderDetailsBean> {

	@Autowired
	IEquipRepairOrderService orderService;

	@Override
	public void process(JSONObject taskBean, EquipRepairOrderDetailsBean detailsBean,
			Map<String, JSONObject> extFormDataJson) throws Exception {

		Integer id = Integer.parseInt(extFormDataJson.get("equip_repair_order").get("id").toString());
		detailsBean.setOrderId(id);

		//orderService.saveRepairOrderDetails(detailsBean);
	}
}
